function SIGEirf(ma_m,ma_a,ma_g,ma_nu,ma_gam)

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%This is part of the set of files that accompany the article:       %
%Mankiw, N. Gregory and Ricardo Reis (2007) "Sticky Information in  %
%General Equilibrium," Journal of the European Economic Association,%
%forthcoming. See the appendix of the NBER or CEPR working paper    %
%versions for a detailed explanation of the algorithms.             %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%Please cite if you use the programs. I do not provide tech support.%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%Last revised: August 30, 2006                                      %
%Written by: Ricardo Reis                                           %
%Input: solution of the model in terms of MA representation         %
%Output: Impulse reponse function of inflation, output gap and hours%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%Columns are series, rows are shocks.
figure
%Monetary shock
subplot(3,3,1), plot(ma_m(1:40,1),'b-','LineWidth',2); title('Inflation'); ylabel('Monetary shock');
subplot(3,3,2), plot(ma_m(1:40,6),'r-','LineWidth',2); title('Output gap');
subplot(3,3,3), plot(ma_m(1:40,5),'g-','LineWidth',2); title('Labor');
%Tech shock
subplot(3,3,4), plot(ma_a(1:40,1),'b-','LineWidth',2); ylabel('Technology shock');
subplot(3,3,5), plot(ma_a(1:40,6),'r-','LineWidth',2);
subplot(3,3,6), plot(ma_a(1:40,5),'g-','LineWidth',2);
%Fiscal shock
subplot(3,3,7), plot(ma_g(1:40,1),'b-','LineWidth',2); ylabel('Aggregate demand shock');
subplot(3,3,8), plot(ma_g(1:40,6),'r-','LineWidth',2);
subplot(3,3,9), plot(ma_g(1:40,5),'g-','LineWidth',2);